package com.victualler.product.department.controller;

import com.victualler.core.base.controller.BaseRestController;
import com.victualler.core.common.dto.PageDto;
import com.victualler.product.department.dto.DepartmentRequestDto;
import com.victualler.product.department.entity.DepartmentDao;
import com.victualler.product.department.repository.DepartmentQueryRepository;
import com.victualler.product.department.repository.DepartmentRepository;
import com.victualler.product.department.service.DepartmentService;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;


/**
 * @author: Guoshichang
 * @discription:
 */
public interface DepartmentController  extends BaseRestController<DepartmentDao,DepartmentRepository,DepartmentQueryRepository,DepartmentService> {

    /**
     * @author Guoshichang
     * @since 13:39 on 2018/7/7.
     * @param departmentRequestDto 请求对象
     * @Function  根据条件入参depotRequestDto动态分页查询权限
     */
    @RequestMapping("/getByRequestDto")
    public PageDto<DepartmentDao> getByRequestDto(@RequestBody DepartmentRequestDto departmentRequestDto, @RequestParam("pageNo") int pageNo, @RequestParam("limit") int limit);

}
